Programming with Multisets
نویسنده
چکیده
This paper proposes a novel way of introducing multisets into declarative programming languages. Starting from a standard deenition of a multiset, suitable operations on multisets are deened and implemented in a declarative programming language, and a variety of programming examples are given to illustrate the utility of the ideas. This approach to multisets is compared with their treatment in the Z speciication language and other approaches in programming languages. Multisets are recognised as being important in speciication but are not normally provided as a fully-edged data type in programming languages. The approach presented here helps to reduce this mismatch.
منابع مشابه
Generalized Multisets for Chemical Programming Jean-pierre Banâtre, Pascal Fradet,
Gamma is a programming model where computation can be seen as chemical reactions between data represented as molecules floating in a chemical solution. This model can be formalized as associative, commutative, conditional rewritings of multisets where rewrite rules and multisets represent chemical reactions and solutions, respectively. In this article, we generalize the notion of multiset used ...
متن کاملGeneralised multisets for chemical programming
Gamma is a programming model where computation can be seen as chemical reactions between data represented as molecules floating in a chemical solution. This model can be formalized as associative, commutative, conditional rewritings of multisets where rewrite rules and multisets represent chemical reactions and solutions, respectively. In this article, we generalize the notion of multiset used ...
متن کاملGeneralized Multisets for Chemical Programming
Gamma is a programming model where computation can be seen as chemical reactions between data represented as molecules floating in a chemical solution. This model can be formalized as associative, commutative, conditional rewritings of multisets where rewrite rules and multisets represent chemical reactions and solutions, respectively. In this article, we generalize the notion of multiset used ...
متن کاملAn Approach to Location Tracking of Mobile Sensors based on Distributed Randomized Multisets
The tracking of location information in mobile ad hoc sensor networks is a well-studied problem for which many solutions have been proposed. The approach discussed in this paper is based on the systematic use of a distributed shared data structure. Specifically, randomized versions of replicated sets and multisets are introduced. It is shown that this probabilistic approach can improve the perf...
متن کاملNested Multisets, Hereditary Multisets, and Syntactic Ordinals in Isabelle/HOL
We present a collection of formalized results about finite nested multisets, developed using the Isabelle/HOL proof assistant. The nested multiset order is a generalization of the multiset order that can be used to prove termination of processes. Hereditary multisets, a variant of nested multisets, offer a convenient representation of ordinals below 0. In Isabelle/HOL, both nested and hereditar...
متن کامل